package com.bondex.charter.dao;

import com.bondex.charter.po.CharterBooking;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface CharterBookingMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(CharterBooking record);

    int insertSelective(CharterBooking record);

    CharterBooking selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(CharterBooking record);

    int updateByPrimaryKeyWithBLOBs(CharterBooking record);

    int updateByPrimaryKey(CharterBooking record);

    //根据委托号查询数据
    CharterBooking selectByOrderNo(@Param("orderNo") String orderNo);
    //根据客户订单号查询数据
    List<CharterBooking> selectByCustomerNo(@Param("customerNo") String customerNo);
    //根据委托号查询数据
    List<CharterBooking> selectListByOrderNo(@Param("list") List<String> list);
    //根据单号更新状态
    int updateBookingStatus(@Param("list") List<String> list,@Param("status") String status);
    //根据甩货更新状态
    int updateDumpGoods(CharterBooking charterBooking);
    //根据委托单号，更新轻重货状态
    int updateBulkyHeavyFlag(@Param("orderNo") String orderNo, @Param("bulkyHeavyFlag") Byte bulkyHeavyFlag);

    List<CharterBooking> selectForLoad();
}